//用户中心的全局变量
let userInfo = {
  avatarUrl:'',//头像url 
  nickName: '',//用户名
  phoneNumber: '13350208172',//用户电话
  gender: 0,//性别
  class:'',//学生班级
  sNumber:'',//学生学号
  userType:''//用户类型
};

const orderTagInfos = [
  {
    orderNum: 1,
    tabType: 5,
  },
  {
    orderNum: 1,
    tabType: 10,
  },
  {
    orderNum: 1,
    tabType: 40,
  },
  {
    orderNum: 0,
    tabType: 0,
  },
];

const customerServiceInfo = {
  servicePhone: '4006336868',
  serviceTimeDuration: '每周三至周五 9:00-12:00  13:00-15:00',
};


wx.request({
  url: 'https://www.fastmock.site/mock/5056e6dab76026e0a4cf097da872d214/example/example/getuser',
  method:'GET',
  success:(res)=>{
    userInfo = res.data.userInfo
  }
})

export const genSimpleUserInfo = () => ({ ...userInfo });

export const genUsercenter = () => ({
  userInfo,
  orderTagInfos,
  customerServiceInfo,
});
